<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="app">
        {{user.name}} <br/>
        {{user.friend.name}}
        <button @click="changeFriendName">change Friend</button>
    </div>
    <script src="https://unpkg.com/vue@next"></script>
    <script>
        const User = {
            setup() {
                const user = Vue.reactive({
                    name: 'john',
                    friend: {
                        name: 'May'
                    }
                })
                const changeFriendName = () => {
                    user.friend.name = '手动阀手动阀'
                }
                return {
                    user,
                    changeFriendName
                }
            }
        }
        Vue.createApp(User).mount('#app')
        console.log(Vue)
    </script>
</body>
</html>